zynqmp: pm: Move pm_client_wakeup call from pm_req_wakeup
authorFilip Drazic <[email protected]>
Tue, 7 Feb 2017 11:03:56 +0000 (12:03 +0100)
committerSiva Durga Prasad Paladugu <[email protected]>
Thu, 17 May 2018 09:41:52 +0000 (15:11 +0530)
Call to pm_client_wakeup from pm_req_wakeup prevented the PM API
call to be used to wake up non-APU processor (e.g. from higher ELs),
since it clears power down request for specified APU processor.
Move this function out of pm_client_wakeup to allow passing wake up
requests to the PMU for other processor in the system.

Signed-off-by: Filip Drazic <[email protected]>
Acked-by: Will Wong <[email protected]>
plat/xilinx/zynqmp/plat_psci.c
plat/xilinx/zynqmp/pm_service/pm_api_sys.c

index c9fd36113e1f425f8d287f34b04389d0566a39ee..27cdddb2c89e9060b7bf772aaf924b19e5543a6f 100644 (file)
@@ -78,6 +78,8 @@ static int zynqmp_pwr_domain_on(u_register_t mpidr)
                return PSCI_E_INTERN_FAIL;
 
        proc = pm_get_proc(cpu_id);
+       /* Clear power down request */
+       pm_client_wakeup(proc);
 
        /* Send request to PMU to wake up selected APU CPU core */
        pm_req_wakeup(proc->node_id, 1, zynqmp_sec_entry, REQ_ACK_BLOCKING);
index cad29bc6c2e5749989f3ba8161d53394cfa7950a..9f137f4bf59a071d8b101bb10e5c33e0f673e3dc 100644 (file)
@@ -130,10 +130,7 @@ enum pm_ret_status pm_req_wakeup(enum pm_node_id target,
 {
        uint32_t payload[PAYLOAD_ARG_CNT];
        uint64_t encoded_address;
-       const struct pm_proc *proc = pm_get_proc_by_node(target);
 
-       /* invoke APU-specific code for waking up another APU core */
-       pm_client_wakeup(proc);
 
        /* encode set Address into 1st bit of address */
        encoded_address = address;